package cn.tedu;

import java.awt.*;
import java.util.Random;

public class Star {
    int x;
    int y;
    Color color;
    Random random=new Random();

    public Star(){


        this.x=random.nextInt(800);
        this.y=random.nextInt(600);

        this.color=new Color(random.nextInt(255),random.nextInt(255),random.nextInt(255));
    }

    public void move(){
        y++;
        if(y>1080){
            y=0;
        }
    }
}
